package coap.messages;

public class ResponseCodes {
	public static final int Created = 65;
	public static final int Deleted = 66;
	public static final int Valid = 67;
	public static final int Changed = 68;
	public static final int Content = 69;
	public static final int BadRequest = 128;
	public static final int Unauthhorized = 129;
	public static final int BadOption = 130;
	public static final int Forbidden = 131;
	public static final int NotFound = 132;
	public static final int MethodNotAllowd = 133;
	public static final int NotAcceptable = 134;
	public static final int PreconditionFailed = 140;
	public static final int RequestEntityTooLarge = 141;
	public static final int UnsupportedMediaType = 143;
	public static final int InternalServerError = 160;
	public static final int NotImplemented = 161;
	public static final int BadGateway = 162;
	public static final int ServiceUnavailable = 163;
	public static final int GatewayTimeout = 164;
	public static final int ProxyNotSupported = 165;
	
	public static String getString(int value){
		switch(value){
		case Created:
			return "Created";
		case Deleted:
			return "Deleted";
		case Valid:
			return "Valid";
		case Changed:
			return "Changed";
		case Content:
			return "Content";
		case BadRequest:
			return "Bad Request";
		case Unauthhorized:
			return "Unauthorized";
		case BadOption:
			return "Bad Option";
		case Forbidden:
			return "Forbidden";
		case NotFound:
			return "Not Found";
		case MethodNotAllowd:
			return "Method Not Allowed";
		case NotAcceptable:
			return "Not Acceptable";
		case PreconditionFailed:
			return "Precondition Failed";
		case RequestEntityTooLarge:
			return "Request Entity Too Large";
		case UnsupportedMediaType:
			return "Unsupported Media Type";
		case InternalServerError:
			return "Internal Server Error";
		case NotImplemented:
			return "Not Implemented";
		case BadGateway:
			return "Bad Gateway";
		case ServiceUnavailable:
			return "Service Unavailable";
		case GatewayTimeout:
			return "Gateway Timeout";
		case ProxyNotSupported:
			return "Proxy Not Supported";
		default:
			return "Unknown";
		}
	}
}
